<h1>Editing bookmark</h1>

<% form_for(@bookmark, :url=>book_bookmark_path(@bookmark.book, @bookmark)) do |f| %>
  <%= f.error_messages %>

  <p>
    <%= f.label :description %><br />
    <%= f.text_field :description %>
  </p>
  <p>
    <%= f.label :page_number %><br />
    <%= f.text_field :page_number %>
  </p>
  <p>
    <% f.fields_for :bounds do |bounds_fields| %>
	  X: <%= bounds_fields.text_field :x %>
	  Y: <%= bounds_fields.text_field :y %>
	  Width: <%= bounds_fields.text_field :width %>
	  Height: <%= bounds_fields.text_field :height %>
	<% end %>
  </p>
  <p>
    <%= f.submit "Update" %>
  </p>
<% end %>

<%= link_to 'Show', book_bookmark_path(@bookmark.book, @bookmark) %> |
<%= link_to 'Back', book_bookmarks_path(@bookmark.book) %>
